<form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">

    <div class="panel panel-default panel-intro">
        <div class="panel-heading">
            <ul class="nav nav-tabs">
                <li class="active"><a href="#base" data-toggle="tab">基础</a></li>
                <li><a href="#merchant" data-toggle="tab">商户</a></li>
                <li><a href="#info" data-toggle="tab">信息</a></li>
            </ul>
        </div>

        <div class="panel-body">
            <div id="myTabContent" class="tab-content">

                <div class="tab-pane fade active in" id="base">
                    <div class="form-group">
                        <label for="c-name" class="control-label col-xs-12 col-sm-2">{:__('Name')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <input id="c-name" data-rule="required" class="form-control" name="row[name]" type="text" value="">
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-typedata" class="control-label col-xs-12 col-sm-2">{:__('Typedata')}:</label>
                        <div class="col-xs-12 col-sm-8">

                            <div class="radio" id="c-typedata">
                            {foreach name="typedataList" item="vo"}
                            <label for="row[typedata]-{$key}"><input id="row[typedata]-{$key}" name="row[typedata]" type="radio" value="{$key}" {in name="key" value="serv_account"}checked{/in} /> {$vo}</label>
                            {/foreach}
                            </div>

                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-token" class="control-label col-xs-12 col-sm-2">{:__('Token')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <input id="c-token" class="form-control" name="row[token]" type="text" value="">
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-appid" class="control-label col-xs-12 col-sm-2">{:__('Appid')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <input id="c-appid" data-rule="required" class="form-control" name="row[appid]" type="text" value="">
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-appsecret" class="control-label col-xs-12 col-sm-2">{:__('Appsecret')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <input id="c-appsecret" data-rule="required" class="form-control" name="row[appsecret]" type="text">
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-aeskey" class="control-label col-xs-12 col-sm-2">{:__('Aeskey')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <input id="c-aeskey" class="form-control" name="row[aeskey]" type="text">
                        </div>
                    </div>
                    <!--<div class="form-group">
                        <label for="c-notify_url" class="control-label col-xs-12 col-sm-2">{:__('Notify_url')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <input id="c-notify_url" class="form-control" name="row[notify_url]" type="text">
                        </div>
                    </div>-->
                    <div class="form-group">
                        <label for="c-original" class="control-label col-xs-12 col-sm-2">{:__('Original')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <input id="c-original" class="form-control" name="row[original]" type="text">
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-wechat" class="control-label col-xs-12 col-sm-2">{:__('Wechat')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <input id="c-wechat" class="form-control" name="row[wechat]" type="text">
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-state" class="control-label col-xs-12 col-sm-2">{:__('State')}:</label>
                        <div class="col-xs-12 col-sm-8" id="c-state">
                            <div class="radio">
                                {foreach name="stateList" item="vo"}
                                <label for="row[state]-{$key}"><input id="row[state]-{$key}" name="row[state]" type="radio" value="{$key}" {in name="key" value="enable"}checked{/in} /> {$vo}</label>
                                {/foreach}
                            </div>
                        </div>
                    </div>
                </div>

                <div class="tab-pane fade" id="merchant">
                    <div class="form-group">
                        <label for="c-mchid" class="control-label col-xs-12 col-sm-2">{:__('Mchid')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <input id="c-mchid" class="form-control" name="row[mchid]" type="text">
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-mchkey" class="control-label col-xs-12 col-sm-2">{:__('Mchkey')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <input id="c-mchkey" class="form-control" name="row[mchkey]" type="text">
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-mch_api_cert" class="control-label col-xs-12 col-sm-2">{:__('Mchcert')}</label>
                        <div class="col-xs-12 col-sm-8">
                            <div class="input-group">
                                <span class="input-group-addon">apiclient_cert</span>
                                <input id="c-mch_api_cert" data-rule="" class="form-control" size="50" name="row[mch_api_cert]" type="text" value="">
                                <div class="input-group-addon no-border no-padding">
                                    <span><button type="button" id="plupload-mch_api_cert" class="btn btn-danger plupload" data-input-id="c-mch_api_cert"
                                                  data-url="wechat/applet/upload"  data-mimetype="pem" data-multiple="false"><i class="fa fa-upload"></i> 上传</button></span>
                                </div>
                            </div>
                            <ul class="row list-inline plupload-preview" id="p-mchcert"></ul>
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-mch_api_key" class="control-label col-xs-12 col-sm-2">{:__('Mchcert')}</label>
                        <div class="col-xs-12 col-sm-8">
                            <div class="input-group">
                                <span class="input-group-addon">apiclient_key</span>
                                <input id="c-mch_api_key" data-rule="applet/upload" class="form-control" size="50" name="row[mch_api_key]" type="text" value="">
                                <div class="input-group-addon no-border no-padding">
                                    <span><button type="button" id="plupload-mch_api_key" class="btn btn-danger plupload" data-input-id="c-mch_api_key"
                                                  data-url="wechat/applet/upload" data-mimetype="pem" data-multiple="false"><i class="fa fa-upload"></i> 上传</button></span>
                                </div>
                            </div>
                            <ul class="row list-inline plupload-preview" id="p-mch_api_key"></ul>
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-mp_appid" class="control-label col-xs-12 col-sm-2">{:__('Mp_appid')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <input id="c-mp_appid" class="form-control" name="row[mp_appid]" type="text" value="">
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-mp_appsecret" class="control-label col-xs-12 col-sm-2">{:__('Mp_appsecret')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <input id="c-mp_appsecret" class="form-control" name="row[mp_appsecret]" type="text">
                        </div>
                    </div>
                </div>

                <div class="tab-pane fade" id="info">
                    <div class="form-group">
                        <label for="c-principal" class="control-label col-xs-12 col-sm-2">{:__('Principal')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <input id="c-principal" class="form-control" name="row[principal]" type="text">
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-headface_image" class="control-label col-xs-12 col-sm-2">{:__('Headface_image')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <div class="input-group">
                                <input id="c-headface_image" class="form-control" size="50" name="row[headface_image]" type="text">
                                <div class="input-group-addon no-border no-padding">
                                    <span><button type="button" id="plupload-headface_image" class="btn btn-danger plupload" data-input-id="c-headface_image" data-mimetype="image/gif,image/jpeg,image/png,image/jpg,image/bmp" data-multiple="false" data-preview-id="p-headface_image"><i class="fa fa-upload"></i> {:__('Upload')}</button></span>
                                    <span><button type="button" id="fachoose-headface_image" class="btn btn-primary fachoose" data-input-id="c-headface_image" data-mimetype="image/*" data-multiple="false"><i class="fa fa-list"></i> {:__('Choose')}</button></span>
                                </div>
                                <span class="msg-box n-right" for="c-headface_image"></span>
                            </div>
                            <ul class="row list-inline plupload-preview" id="p-headface_image"></ul>
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-qrcode_image" class="control-label col-xs-12 col-sm-2">{:__('Qrcode_image')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <div class="input-group">
                                <input id="c-qrcode_image" class="form-control" size="50" name="row[qrcode_image]" type="text">
                                <div class="input-group-addon no-border no-padding">
                                    <span><button type="button" id="plupload-qrcode_image" class="btn btn-danger plupload" data-input-id="c-qrcode_image" data-mimetype="image/gif,image/jpeg,image/png,image/jpg,image/bmp" data-multiple="false" data-preview-id="p-qrcode_image"><i class="fa fa-upload"></i> {:__('Upload')}</button></span>
                                    <span><button type="button" id="fachoose-qrcode_image" class="btn btn-primary fachoose" data-input-id="c-qrcode_image" data-mimetype="image/*" data-multiple="false"><i class="fa fa-list"></i> {:__('Choose')}</button></span>
                                </div>
                                <span class="msg-box n-right" for="c-qrcode_image"></span>
                            </div>
                            <ul class="row list-inline plupload-preview" id="p-qrcode_image"></ul>
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-signature" class="control-label col-xs-12 col-sm-2">{:__('Signature')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <textarea id="c-signature" class="form-control " rows="5" name="row[signature]" cols="50"></textarea>
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="c-city" class="control-label col-xs-12 col-sm-2">{:__('City')}:</label>
                        <div class="col-xs-12 col-sm-8">
                            <div class='control-relative'><input id="c-city" class="form-control" data-toggle="city-picker" name="row[city]" type="text"></div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-success btn-embossed disabled">{:__('OK')}</button>
            <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
        </div>
    </div>
</form>
